<%@tag pageEncoding="UTF-8" isELIgnored="false"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %> 
<%@attribute name="url" required="true"%>
<%@attribute name="formId" required="true" %>
总共<font color="red" ><c:out value="${pagination.totalLines}" /></font>条记录 当前第<font color="red"><c:out value="${pagination.currentPage}"/></font>页
		<a href="javascript:gotoPage(1,${pagination.pageSize})">首页</a>
		<c:choose>
			<c:when test="${pagination.hasPrePage}">
				<a href="javascript:gotoPage(${pagination.currentPage-1},${pagination.pageSize})">上一页</a>
			</c:when>
			<c:otherwise>
				上一页
			</c:otherwise>
		</c:choose>
		<c:choose>
			<c:when test="${pagination.hasNextPage}">
				<a href="javascript:gotoPage(${pagination.currentPage+1},${pagination.pageSize})">下一页</a>
			</c:when>
			<c:otherwise>
				下一页
			</c:otherwise>
		</c:choose>

		<a href="javascript:gotoPage(${pagination.totalPages},${pagination.pageSize})">末页</a>
		转到第<select onchange="javascript:gotoPage(this.value,${pagination.pageSize })">
			<c:forEach begin="1" end="${pagination.totalPages}" var="i">
				<option value="${i}" <c:if test="${i==pagination.currentPage}">selected</c:if> >${i}</option>
			</c:forEach>
		</select>页
		&nbsp;&nbsp;&nbsp;每页显示
		<select onchange="javascript:gotoPage(${pagination.currentPage },this.value)">
				<option value="5" <c:if test="${5==pagination.pageSize}">selected</c:if> >5</option>
				<option value="10" <c:if test="${10==pagination.pageSize}">selected</c:if> >10</option>
				<option value="20" <c:if test="${20==pagination.pageSize}">selected</c:if> >20</option>
				<option value="30" <c:if test="${30==pagination.pageSize}">selected</c:if> >30</option>
				<option value="50" <c:if test="${50==pagination.pageSize}">selected</c:if> >50</option>
				<option value="100" <c:if test="${100==pagination.pageSize}">selected</c:if> >100</option>
				<option value="200" <c:if test="${200==pagination.pageSize}">selected</c:if> >200</option>
		</select>条记录
<script langue="javascript" type="text/javascript">
	function gotoPage(page,size){
		var form=document.getElementById("${formId}");
		if("${url}".indexOf("?")<0){
		form.action="${url}?page="+page+"&size="+size;}
		else{
		form.action="${url}&page="+page+"&size="+size;
		}
		form.submit();
	}
</script>